package com.abstractfactory;

/**
 * @author sailor wang
 * @date 2018/8/31 上午10:51
 * @description
 */
public class Main {
    public static void main(String[] args) {
        AbstractFactory shapeFactory = FactoryProducer.getFactory("shape");

        shapeFactory.getShape("circle").draw();

        shapeFactory.getShape("square").draw();

        shapeFactory.getShape("rectangle").draw();

        AbstractFactory colorFactory = FactoryProducer.getFactory("color");

        colorFactory.getColor("red").fill();

        colorFactory.getColor("blue").fill();

        colorFactory.getColor("green").fill();

    }
}